import 'package:kkhousekeep/generated/json/base/json_convert_content.dart';
import 'package:kkhousekeep/models/repair_order_result_entity.dart';

RepairOrderResultEntity $RepairOrderResultEntityFromJson(Map<String, dynamic> json) {
	final RepairOrderResultEntity repairOrderResultEntity = RepairOrderResultEntity();
	final int? code = jsonConvert.convert<int>(json['code']);
	if (code != null) {
		repairOrderResultEntity.code = code;
	}
	final RepairOrderResultObj? obj = jsonConvert.convert<RepairOrderResultObj>(json['obj']);
	if (obj != null) {
		repairOrderResultEntity.obj = obj;
	}
	final String? msg = jsonConvert.convert<String>(json['msg']);
	if (msg != null) {
		repairOrderResultEntity.msg = msg;
	}
	return repairOrderResultEntity;
}

Map<String, dynamic> $RepairOrderResultEntityToJson(RepairOrderResultEntity entity) {
	final Map<String, dynamic> data = <String, dynamic>{};
	data['code'] = entity.code;
	data['obj'] = entity.obj.toJson();
	data['msg'] = entity.msg;
	return data;
}

RepairOrderResultObj $RepairOrderResultObjFromJson(Map<String, dynamic> json) {
	final RepairOrderResultObj repairOrderResultObj = RepairOrderResultObj();
	final String? fatalType = jsonConvert.convert<String>(json['fatalType']);
	if (fatalType != null) {
		repairOrderResultObj.fatalType = fatalType;
	}
	final String? repairStandard = jsonConvert.convert<String>(json['repairStandard']);
	if (repairStandard != null) {
		repairOrderResultObj.repairStandard = repairStandard;
	}
	final String? result = jsonConvert.convert<String>(json['result']);
	if (result != null) {
		repairOrderResultObj.result = result;
	}
	final String? cause = jsonConvert.convert<String>(json['cause']);
	if (cause != null) {
		repairOrderResultObj.cause = cause;
	}
	final String? propose = jsonConvert.convert<String>(json['propose']);
	if (propose != null) {
		repairOrderResultObj.propose = propose;
	}
	final List<String>? pics = jsonConvert.convertListNotNull<String>(json['pics']);
	if (pics != null) {
		repairOrderResultObj.pics = pics;
	}
	return repairOrderResultObj;
}

Map<String, dynamic> $RepairOrderResultObjToJson(RepairOrderResultObj entity) {
	final Map<String, dynamic> data = <String, dynamic>{};
	data['fatalType'] = entity.fatalType;
	data['repairStandard'] = entity.repairStandard;
	data['result'] = entity.result;
	data['cause'] = entity.cause;
	data['propose'] = entity.propose;
	data['pics'] =  entity.pics;
	return data;
}